﻿using System;
using System.Collections.Generic;

namespace CopyRightCodeCollector.Collectors {
    public class TotalLineCollector : LineCollector {

        private int count;

        public TotalLineCollector(string outputPath, Action<string, IEnumerable<string>> outputer) : base(outputPath, outputer) {
            this.count = 0;
        }

        public override void Add(string line) {
            this.count++;
        }

        protected override void Output() {
            base.Add($"Total Lines: {this.count}");
            base.Output();
        }
    }
}
